import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';

import { ApiProperty } from '@nestjs/swagger';
import { BaseEntity } from '../base.entity';

@Entity({ name: 'sys_group' })
export default class SysGroup extends BaseEntity {
  @PrimaryGeneratedColumn({ type: 'bigint' })
  @ApiProperty()
  id: number;

  @ApiProperty()
  @Column()
  name: string;

  @ApiProperty()
  @Column({ name: 'create_user_id', type: 'bigint' })
  createUserId: number;

  @ApiProperty()
  @Column()
  description: string;

  @ApiProperty()
  @Column()
  status: number;

  @ApiProperty()
  @Column()
  logo: string;

  @ApiProperty()
  @Column()
  type: number;

  @ApiProperty()
  @Column()
  user_number: number;

  @ApiProperty()
  @Column({ name: 'project_count' })
  projectCount: number;

  @ApiProperty()
  @Column({ name: 'user_count' })
  userCount: number;

  @ApiProperty()
  @Column()
  visibilitylevel: number;
}
